//
// Created by Administrator on 24-8-10.
//

#ifndef CPPROJ_W25QXXCLASS_H
#define CPPROJ_W25QXXCLASS_H

#include "main.h"
//#include "W25QXX.h"

/**
 * 读写芯片内容
 */
class W25QXXClass {

public:
    W25QXXClass();

    uint8_t InitW25Q();

    void PrintID();

    void TestReadWrite();



private:
    GPIO_TypeDef* cs_gpio_port_; // GPIO 端口
    uint16_t cs_pin_;            // GPIO 引脚

    uint8_t wData[0x100];   //写缓存数组
    uint8_t rData[0x100];   //读缓存数组
    uint8_t ID[4];          //设备ID缓存数组
    uint32_t i;
};


#endif //CPPROJ_W25QXXCLASS_H
